<?php if(!defined("HDPHP_PATH"))exit;C("SHOW_NOTICE",FALSE);?><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<title>列表页</title>
<link rel="stylesheet/less" type="text/css" href="http://localhost/baidusale/Application/Index/View/Public/css/list.less" />
<!-- head -->
<?php if(!defined("HDPHP_PATH"))exit;C("SHOW_NOTICE",FALSE);?><link rel="stylesheet/less" type="text/css" href="http://localhost/baidusale/Application/Index/View/Public/css/head-foot.less" />
<script src="http://localhost/baidusale/Application/Index/View/Public/js/less.js" type="text/javascript"></script>
<script src="http://localhost/baidusale/Application/Index/View/Public/js/jquery.js" type="text/javascript"></script>
<script type="text/javascript">
$(function(){
    // 登录
    $('#login').click(function(){
        $('.login-kuang').css("display","block");
    })
    $('.login-close').click(function(){
        $('.login-kuang').css("display","none");
    })
    // 注册
    $('#regist').click(function(){
        $('.regist-kuang').css("display","block");
    })
    $('.regist-close').click(function(){
        $('.regist-kuang').css("display","none");
    })
})
</script>
<script type='text/javascript' src='http://localhost/baidusale/hdphp/Extend/Org/Jquery/jquery-1.8.2.min.js'></script>
<link href='http://localhost/baidusale/hdphp/hdjs/css/hdjs.css' rel='stylesheet' media='screen'>
<link href='http://localhost/baidusale/hdphp/hdjs/css/hdvalidate.css' rel='stylesheet' media='screen'>
<script src='http://localhost/baidusale/hdphp/hdjs/js/hdjs.js'></script>
<script src='http://localhost/baidusale/hdphp/hdjs/js/hdvalidate.js'></script>
<script src='http://localhost/baidusale/hdphp/hdjs/js/slide.js'></script>
<script src='http://localhost/baidusale/hdphp/hdjs/org/cal/lhgcalendar.min.js'></script>
<script type='text/javascript'>
HOST = '<?php echo $GLOBALS['user']['HOST'];?>';
ROOT = '<?php echo $GLOBALS['user']['ROOT'];?>';
WEB = '<?php echo $GLOBALS['user']['WEB'];?>';
URL = '<?php echo $GLOBALS['user']['URL'];?>';
APP = '<?php echo $GLOBALS['user']['APP'];?>';
COMMON = '<?php echo $GLOBALS['user']['COMMON'];?>';
HDPHP = '<?php echo $GLOBALS['user']['HDPHP'];?>';
HDPHPDATA = '<?php echo $GLOBALS['user']['HDPHPDATA'];?>';
HDPHPEXTEND = '<?php echo $GLOBALS['user']['HDPHPEXTEND'];?>';
MODULE = '<?php echo $GLOBALS['user']['MODULE'];?>';
CONTROLLER = '<?php echo $GLOBALS['user']['CONTROLLER'];?>';
ACTION = '<?php echo $GLOBALS['user']['ACTION'];?>';
STATIC = '<?php echo $GLOBALS['user']['STATIC'];?>';
HDPHPTPL = '<?php echo $GLOBALS['user']['HDPHPTPL'];?>';
VIEW = '<?php echo $GLOBALS['user']['VIEW'];?>';
PUBLIC = '<?php echo $GLOBALS['user']['PUBLIC'];?>';
CONTROLLERVIEW = '<?php echo $GLOBALS['user']['CONTROLLERVIEW'];?>';
</script>
<script src="http://localhost/baidusale/Application/Index/View/Public/js/js.js" type="text/javascript"></script>

</head>
<body>
<!-- 头部开始 -->
<div id="top">
    <a id="logo" href="/waimai"></a>
    <div id="change">
        <div></div>
        <input type="text" value="烟云村">
        <a href="">切换</a>
    </div>
    <ul>
        <a href=""><li style="background:#dc1432;">外卖</li></a>
        <a href=""><li>我的订单</li></a>
        <a href=""><li>联系我们</li></a>
    </ul>
    <div id="in">
         <a id="login" href="###">登录</a>
         <a id="regist" href="###">注册</a>
    </div>
    <div id="user"><a href="">欢迎<?php echo $_SESSION['username'];?>回来</a></div>
    <!-- 登陆框 -->
    <div class="login-kuang">
        <div class="login-kuang-top">
            <div class="login-kuang-top1"></div>
            <div class="login-kuang-top2">登录百度账号</div>
            <div class="login-close"></div>
        </div>
        <form id="LoginForm" action="" method="post">
            <div class="user">
                <div class="user-left"></div>
                <input type="text" name="user" value="凯爵爷">
                <div class="user-right"></div>
            </div>
            <div class="password">
                <div class="password-left"></div>
                <input type="text" name="password" value="密码">
                <div class="password-right"></div>
            </div>
            <div class="auto">
                <input type="checkbox" checked="checked"  name="auto">
                <span>&nbsp;&nbsp;下次自动登录</span>
                <a href="">忘记密码？</a>
            </div>
            <input type="submit" name="submit" class="submit" value="登录">
            <a class="lijizhuce" href="">立即注册</a>
        </form>
        <a href=""></a>
    </div>

 <!-- 注册框 -->
    <div class="regist-kuang">
        <div class="regist-kuang-top">
            <div class="regist-kuang-top1"></div>
            <div class="regist-kuang-top2">注册百度账号</div>
            <div class="regist-close"></div>
        </div>
        <form id="regForm" action="javascript:;" method="post">
            <div>
                <span>用户名</span>
                <input class="user" type="text" name="username_reg">
            </div>
            <div>
                <span>密码</span>
                <input class="password1" type="text" name="password1">
            </div>
            <div>
                <span>确认密码</span>
                <input class="password2" type="text" name="password2">
            </div>
            <div>
                <span>验证码</span>
                <input class="code" type="text" name="code"> 
               
            </div>    
            <img id="code" src="<?php echo U('Regist/code');?>" alt="" onclick="this.src=this.src + '&' + Math.random()">        
            <div class="auto">
                <input type="checkbox" checked="checked"  name="auto">
                <span>&nbsp;&nbsp;我已阅读并接受<a href="">《百度用户协议》</a></span>
            </div>
            <input type="submit" name="submit" class="submit" value="注册">          
        </form>
        <a class="yiyou" href="">登录已有账号</a>
    </div>    
</div>
<script type="text/javascript">
    var cid = '<?php echo _default($_GET['cid'],0);?>';
    var tagid = '<?php echo _default($_GET['tagid'],0);?>';
</script>
<script src="http://localhost/baidusale/Application/Index/View/Public/js/list.js" type="text/javascript"></script>
<!-- 广告图片 -->
<a id="ad" href=""></a>
<!-- 产品列表 -->
<?php
    $cid=$_GET['cid'];
    $tagid = explode(',', rtrim($_GET['tagid'],','));
    // p($tagid);die;
?>
<ul id="list">
    <a href="<?php echo U('List/index');?>">
        <li class="all_store <?php if($cid == 0){?>all_this<?php }?>">
            <div class="div0"></div>
            <span style="color: #ff2d4b;">全部</span>
            <div class="sanjiao1" style="display:block;"></div>
         </li>
    </a>

    <?php if(is_array($cate_data)){?><?php  foreach($cate_data as $key=>$v){ ?>
    <a href="<?php echo U('List/index',array('cid'=>$v['cid']));?>">
        <li>
            <div class="div<?php echo $v['cid'];?>"></div>
            <span><?php echo $v['cname'];?></span>
            <div class="sanjiao2"></div>
        </li>        
    </a>
    <?php }}?>
</ul>
<!-- 列表下布局 -->
<div id="listdown">
    <div id="listdown_left">
    <?php if(is_array($tag_data)){?><?php  foreach($tag_data as $key=>$v){ ?>
        <span  data-type='<?php echo $v['tagid'];?>' class="tag_search <?php if(in_array($v['tagid'],$tagid)){?>tag_this<?php }?>"><div></div><?php echo $v['content'];?></span>
    <?php }}?>    
    </div>
    <form id="listdown_form" action="" method="">
        <input class="kuang" type="text" value="输入餐厅名搜索">
        <input class="submit" type="submit" value="">
    </form>
</div>
<!-- 店铺 -->
<ul id="dianpu">
    <?php if(is_array($sto_data)){?><?php  foreach($sto_data as $key=>$v){ ?> 
        <li>
            <a href="<?php echo U('Content/index',array('sid'=>$v['sid']));?>"><div class="img"><img src="http://localhost/baidusale/<?php echo $v['store_picture'];?>" alt=""></div></a>
            <div class="dianpu1"><?php echo $v['name'];?></div>
            <div class="dianpu2"><div class="star1"><div class="star2"></div></div>&nbsp;&nbsp;已售<?php echo $v['sendnum'];?>份</div>
            <div class="dianpu3">起送: ¥<?php echo $v['start_price'];?>&nbsp;&nbsp;&nbsp;配送: ¥<?php echo $v['sendprice'];?>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<?php echo $v['sendtime'];?>分钟</div>
            <?php 
               $tag = explode(',', rtrim($v['tag'],',')); 
               // p($tag);
            ?>
            <div class="tag">
                <div class="tags1" style="display:none; <?php if(in_array(3,$tag)){?>display:block;<?php }?>"></div>
                <div class="tags2" style="display:none; <?php if(in_array(2,$tag)){?>display:block;<?php }?>"></div>
                <div class="tags3" style="display:none; <?php if(in_array(1,$tag)){?>display:block;<?php }?>"></div>
            </div>
            <div class="dianpu_show">
                <div class="dianpu_show_top"><?php echo $v['name'];?></div>
                <div class="dianpu_show_tag">            
                    <div class="tags1" style="display:none; <?php if(in_array(3,$tag)){?>display:block;<?php }?>"><div></div><span>下单免配送费</span></div>
                    <div class="tags2" style="display:none; <?php if(in_array(2,$tag)){?>display:block;<?php }?>"><div></div><span>下单立减8元,每天两单</span></div>
                    <div class="tags3" style="display:none; <?php if(in_array(1,$tag)){?>display:block;<?php }?>"><div></div><span>支持开发票</span></div>
                </div>
                <div class="dianpu_show_ads">
                    <div>商家公告</div>
                    <p><?php echo $v['ads'];?></p>
                </div>
                <div class="dianpu_show_sj"></div>
            </div>
        </li>
    <?php }}?> 
</ul>
<!-- foot -->
<?php if(!defined("HDPHP_PATH"))exit;C("SHOW_NOTICE",FALSE);?><!-- foot -->
<div id="foot">
    <ul class="foot_top">
        <li>   
            <h3>帮助</h3>
            <a href="">使用帮助</a>
            <a href="">常见问题</a>
            <a href="">建议与反馈</a>
        </li>
        <div class="line"></div>
        <li>
            <h3>关注我们</h3>
            <a href="">新浪微博</a>
            <a href="">微信公众号</a>
            <a href="">APP下载</a>
        </li>
        <div class="line"></div>
        <li>
            <h3>商务合作</h3>
            <a href="">邮箱：waimai-zhaoshang@baidu.com</a>
        </li>
        <div class="line"></div>
        <li>
            <h3  style="font-size:19.2px;"><div id="kefu"></div>客服热线</h3>
            <span id="span1">400-011-7777</span>
            <span id="span2">周一至周日9:00-22:00</span>

        </li>
    </ul>
    <div class="foot_botton">
        <img src="http://localhost/baidusale/Application/Index/View/Public/images/7.png" alt="">
        <span>&nbsp;© 2014 Baidu<a href="">使用百度前必读</a></span>
    </div>
</div>